﻿namespace Jim.OA;

/// <summary>
/// 删除消息
/// </summary>
[Sdk("/api/ec/dev/message/deleteCustomMessageSingle",description: "删除消息")]
public class OADeleteMessageInput : ISdkRequest<OADeleteMessageOutput>,ISdkCustomDic
{
    /// <summary>
    /// 消息来源code+"|"+业务id 删除消息时所依据的条件
    /// </summary>
    public string TargetId { get; set; }
    /// <summary>
    /// 消息来源code(传了代表code也做为删除时的条件，默认不传）
    /// </summary>
    public string Code { get; set; }
    /// <summary>
    /// 接收人OA系统id
    /// </summary>
    public string UserIdList { get; set; }
    /// <summary>
    /// 接收人登录名
    /// </summary>
    public string LoginIdList { get; set; }
    /// <summary>
    /// 接收人编号
    /// </summary>
    public string WorkCodeList { get; set; }
    /// <summary>
    /// 接收人接收人姓名
    /// </summary>
    public string LastNameList { get; set; }

    public SdkDictionary Dic()
    {
        SdkDictionary dic = new SdkDictionary();
        if (!string.IsNullOrEmpty(Code)) dic.Add("code", Code);
        if (!string.IsNullOrEmpty(UserIdList)) dic.Add("userIdList", UserIdList);
        if (!string.IsNullOrEmpty(LoginIdList)) dic.Add("loginIdList", LoginIdList);
        if (!string.IsNullOrEmpty(WorkCodeList)) dic.Add("workCodeList", WorkCodeList);
        if (!string.IsNullOrEmpty(LastNameList)) dic.Add("lastNameList", LastNameList);
        if (!string.IsNullOrEmpty(TargetId)) dic.Add("targetId", TargetId);
        return dic;
    }
}

public class OADeleteMessageOutput : SdkResponse { 

}